#define _CRT_SECURE_NO_WARNINGS 1
#include<stdio.h>
int erfen(int kay,int arr[],int len)
{
	int left = 0, right;
	int mid;
	right = len - 1;
	while (left <= right)
	{
		mid = (right + left) / 2;
		if (kay > arr[mid])
			left = mid + 1;
		if (kay < arr[mid])
			right = mid - 1;
		if (kay ==arr[mid])
			return mid;
		if(left>right)
			return -1;
	}
}
int main()
{
	int kay,len=0;
	int arr[10] = { 1,2,3,4,5,6,7,8,9,10 };
	while (scanf("%d", &kay) != EOF) {
		len = sizeof(arr) / sizeof(arr[0]);
		printf("%d", erfen(kay, arr, len));
	}
	return 0;
}